package datamanagers;

import java.sql.SQLException;
import java.util.HashMap;
import java.util.List;

import org.apache.commons.configuration.ConfigurationException;

import commons.*;

public abstract class DataManager {

	public abstract void close() throws DataManagerException;

	public abstract UserRatingList getRatings(int UserId)
			throws DataManagerException;

	public abstract UserRatingList getScores(int UserId)
			throws DataManagerException;

	public abstract int getRating(int UserId, int ProfileId)
			throws DataManagerException;

	public abstract void init() throws DataManagerException;

	public abstract HashMap<Integer, Integer> getAllUsers()
			throws DataManagerException;

	public abstract void storeUserSimilarities(List<SimilarityItem> similarities)
			throws DataManagerException;

	public abstract void loadRatings() throws ConfigurationException,
			SQLException;

	public abstract void loadUsers() throws ConfigurationException,
			SQLException;

	public abstract List<Integer> intersezioneRatingList(int UserId1,
			int UserId2) throws DataManagerException;

	public abstract UserRatingMap getRatingsMap(int UserId)
			throws DataManagerException;

	public abstract UserRatingMap getScoresMap(int UserId)
			throws DataManagerException;

	public abstract HashMap<Integer, Float> getMappaMediaUser()
			throws DataManagerException;

	public abstract float getMediaUser(int UserId) throws DataManagerException;

	public abstract HashMap<Integer, Float> getMappaMediaProfile()
			throws DataManagerException;

	// public abstract IntersezioneRating getIntersezioneRating(int UserId1, int
	// UserId2) throws DataManagerException;
	public abstract void storeProfileSimilary(HashMap<Integer, SimilarityItem> similarities)
			throws DataManagerException;

	public IntersezioneRating getIntersezioneRating(int UserId1, int UserId2)
			throws DataManagerException {
		// TODO Auto-generated method stub
		return null;
	}

}
